//
//  UserInfoView.m
//  联付商圈
//
//  Created by apple on 2017/10/31.
//  Copyright © 2017年 lianfu. All rights reserved.
//

#import "UserInfoView.h"

@implementation UserInfoView

- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        self.titleLabel = [[UILabel alloc] initWithFrame:CGRectMake(15 * FONTSIZE, 0, 50 * FONTSIZE, frame.size.height)];
        self.titleLabel.font = [UIFont systemFontOfSize:14];
        [self addSubview:_titleLabel];
        
        self.txtField = [[UITextField alloc] initWithFrame:CGRectMake(72 * FONTSIZE, 3 * FONTSIZE, frame.size.width - 118 * FONTSIZE, frame.size.height - 3 * FONTSIZE)];
        self.txtField.font = [UIFont systemFontOfSize:14];
        [self addSubview:_txtField];
        
        self.arrowImgView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"arrow@2x"]];
        self.arrowImgView.frame = CGRectMake(frame.size.width - 16 * FONTSIZE, (frame.size.height - 12.5 * FONTSIZE) / 2, 7.5 * FONTSIZE, 12.5 * FONTSIZE);
        [self addSubview:_arrowImgView];
    }
    return self;
    
}

- (void)hideArrow:(BOOL)hide
{
    if (hide) {
        self.arrowImgView.hidden = YES;
    }
}

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
